
function usingExtJs() {
    try {
        Ext.Ajax.request({
            url: "/addama-users/whoami",
            method: "GET",
            failure: function(result) {
                if (result.status = 401) {
                    document.location = "login.html?login_success=" + document.location.href;
                }
            }
        });
        return true;
    } catch (e) {
        console.log("warn:" + e);
    }
    return false;
}

usingExtJs();
